var DIRECT = "DIRECT";
var BLACKHOLE = "PROXY 149.3.177.24:443";
//var BLACKHOLE = "PROXY 192.168.0.1:443";

function s(u, r) {
	return shExpMatch(u, r);
} 

function d(h, r) {
	return dnsDomainIs(h, r);
}

function n(h, r, m) {
	return isInNet(h, r, m);
}

function FindProxyForURL(url, host) {
    var u = url.toLowerCase();
    var h = host.toLowerCase();
	
    if (
      //fuckoff
      (d(h, "facebook.com")) ||
    
      //Analytics
     	(d(h, "crashlytics.com")) || 
       (d(h, "testflightapp.com")) || 
       (d(h, "flurry.com")) || 
       (d(h, "google-analytics.com")) || 
       (d(h, "localytics.com")) || 
       (d(h, "appsflyer.com")) || 
       (d(h, "appsdt.com")) || 
       (d(h, "ad-x.co.uk")) || 
       (d(h, "apsalar.com")) || 
       (d(h, "crittercism.com")) || 
       (d(h, "georiot.com")) || 
       (d(h, "kontagent.net")) || 
       (d(h, "mathtag.com")) || 
       (d(h, "mixpanel.com")) || 
       (d(h, "mobileapptracking.com")) || 
       (d(h, "quantserve.com")) || 
       (d(h, "revsci.net")) || 
       (d(h, "scorecardresearch.com")) || 
       (d(h, "sessionm.com")) || 
       (d(h, "urbanairship.com")) || 

       (d(h, "analytics.xvision.me")) ||
       (d(h, "appsee.com")) ||
       (d(h, "wally.me")) ||
	
      
      
      //Ads
      
	(d(h, "adap.tv")) || 
	(d(h, "adblade.com")) || 
	(d(h, "adbn.ru")) || 
	(d(h, "adbomb.ru")) || 
	(d(h, "adbooth.net")) || 
	(d(h, "adcash.com")) || 
	(d(h, "adcast.ru")) || 
	(d(h, "adcolony.com") && !s(u, "configure")) || 
	(d(h, "adcomplete.ru")) || 
	(d(h, "adexprt.com")) || 
	(d(h, "adflow.ru")) || 
	(d(h, "adfog.ru")) || 
	(d(h, "adfonic.net")) || 
	(d(h, "adform.com") || d(h, "adform.net")) || 
	(d(h, "adfox.ru")) || 
	(d(h, "adhands.ru")) || 
	(d(h, "adhese.com")) || 
	(d(h, "adhub.ru")) || 
	(d(h, "adinch.com")) || 
	(d(h, "adinfuse.com")) || 
	(d(h, "adition.com")) || 
	(d(h, "adjuggler.net")) || 
	(d(h, "akncdn.com") || d(h, "adkeeper.com") || d(h, "ackak.com")) || 
	(d(h, "luxup.ru")) || 
	(d(h, "admarvel.com") || s(u, "*admarvel*.amazonaws.com")) || 
	(d(h, "admaster.net")) || 
	(d(h, "atemda.com") || d(h, "admeta.com")) || 
	(d(h, "admob.com")) || 
	(d(h, "adver.mobi") || d(h, "admobi.ru")) || 
	(d(h, "admulti.ru")) || 
	(d(h, "adocean.pl")) || 
	(d(h, "adorika.net")) || 
	(d(h, "adotube.com")) || 
	(d(h, "adpro.com.ua")) || 
	(d(h, "madsone.com")) || 
	(d(h, "adriver.ru")) || 
	(d(h, "adrock.ru") || d(h, "adrock.ua") || d(h, "adrock.com.ua")) || 
	(d(h, "adroll.com")) || 
	(d(h, "adshost2.com")) || 
	(d(h, "adsniper.ru")) || 
	(d(h, "adspirit.de")) || 
	(d(h, "adstark.ru")) || 
	(d(h, "4dsply.com")) || 
	(d(h, "ad-sys.com")) || 
	(d(h, "adtaily.pl") || d(h, "adtaily.com")) || 
	(d(h, "adtech.de")) || 
	(d(h, "adtechus.com")) || 
	(d(h, "adtilt.com") && !s(u, "*configure*")) || 
	(d(h, "adtoma.com")) || 
	(d(h, "adtotal.pl")) || 
	(d(h, "adtrace.org")) || 
	(d(h, "adnxs.com") || d(h, "adversal.com")) || 
	(d(h, "adview.pl")) || 
	(d(h, "am15.net")) || 
	(d(h, "advolution.de")) || 
	(d(h, "adwhirl.com")) || 
	(d(h, "adzerk.net") || d(h, "adzerk.com")) || 
	(d(h, "altrooz.com")) || 
	(d(h, "amazon-adsystem.com")) || 
	(d(h, "amobee.com")) || 
	(d(h, "advertising.com") || d(h, "atwola.com")) || 
	(d(h, "appflood.com")) || 
	(d(h, "applifier.com")) || 
	(d(h, "applovin.com")) || 
	(d(h, "apprupt.com")) || 
	(d(h, "atdmt.com")) || 
	(d(h, "bcfads.com")) || 
	(d(h, "bnmla.com")) || 
	(d(h, "brightroll.com") || d(h, "brightroll.de") || d(h, "btrll.com")) || 
	(d(h, "bubblesmedia.ru")) || 
	(d(h, "appads.com")) || 
	(d(h, "buysellads.com")) || 
	(d(h, "carbonads.com") || d(h, "carbonads.net")) || 
	(d(h, "chartboost.com")) || 
	(n(h, "89.207.18.0", "255.255.255.0  ")) || 
	(d(h, "content.ad")) || 
	(d(h, "cpmstar.com")) || 
	(d(h, "doubleclick.net") && !s(u, "*ythome*")) || 
	(s(u, "*.emediate.*/*") || s(u, "*/eas?c*")) || 
	(d(h, "epom.com")) || 
	(d(h, "exoclick.com")) || 
	(d(h, "exponential.com")) || 
	(s(u, "*.flipboard.com/flipmag/adManager.js") || s(u, "*.flipboard.com/*/adcreative/*") || s(u, "*.flipboard.com/*adname*") || s(u, "*.flipboard.com/flare/*")) || 
	(d(h, "ads.flurry.com")) || 
	(d(h, "fwmrm.net")) || 
	(s(u, "*/pagead2.googlesyndication.com/*") || d(h, "googletagservices.com") || d(h, "googleadservices.com") || s(u, "*.google.*/*ads.js*")) || 
	(d(h, "googleadservices.com") && !s(u, "*/aclk?*")) || 
	(d(h, "greystripe.com")) || 
	(d(h, "hot-mob.com")) || 
	(d(h, "hotwords.com")) || 
	(d(h, "inmobi.com") || d(h, "inmobicdn.net") || s(h, "inmobisdk*.akamaihd.net") || d(h, "appsdt.com")) || 
	(d(h, "inner-active.mobi")) || 
	(d(h, "innovid.com")) || 
	(d(h, "integral-marketing.com")) || 
	(d(h, "nend.net") || d(h, "adimg.net") || d(h, "adingo.jp") || d(h, "adlantis.jp") || d(h, "ad-v.jp") || d(h, "ad-stir.com") || d(h, "amoad.com")) || 
	(d(h, "app-c.net") || d(h, "behaviad.net") || d(h, "i2i.jp") || d(h, "i-mobile.co.jp") || d(h, "ad.maist.jp") || d(h, "microad.jp") || d(h, "medibaad.com") || d(h, "unthem.com")) || 
	(d(h, "a.jumptap.com")) || 
	(d(h, "ligatus.com")) || 
	(d(h, "lijit.com")) || 
	(d(h, "liverail.com")) || 
	(d(h, "madsone.com") || d(h, "mads.com")) || 
	(d(h, "madvertise.de") || d(h, "uimserv.net")) || 
	(d(h, "marketgid.com")) || 
	(d(h, "m2pub.com")) || 
	(d(h, "mdotm.com")) || 
	(d(h, "adland.ru")) || 
	(d(h, "medialytics.com") || d(h, "medialets.com")) || 
	(d(h, "bs.serving-sys.com") || d(h, "smartclip.net") || d(h, "eyewonder.com")) || 
	(d(h, "mgid.com")) || 
	(d(h, "mydas.mobi")) || 
	(d(h, "mobclix.com")) || 
	(d(h, "mobfox.com")) || 
	(d(h, "mobilefuse.net") || d(h, "mobilefuse.com")) || 
	(d(h, "mobiletheory.com")) || 
	(d(h, "mocean.mobi")) || 
	(d(h, "ads.mojiva.com") || s(u, "*ads*.mojiva.com/*")) || 
	(d(h, "mopub.com")) || 
	(s(u, "*msn.com/adsadclient*")) || 
	(s(u, "*admax.nexage.com/*")) || 
	(d(h, "nuggad.net")) || 
	(d(h, "openx.org") || d(h, "openxenterprise.com") || s(u, "*/openx/www/delivery/*.php*") || s(h, "*/openx/www/api/v*/*.php*") || d(h, "openx.com") || d(h, "openx.net")) || 
	(d(h, "openvideoads.org")) || 
	(d(h, "playhaven.com")) || 
	(d(h, "playnomics.net")) || 
	(d(h, "adk2.co")) || 
	(d(h, "pflexads.com")) || 
	(d(h, "popadscdn.net")) || 
	(d(h, "propellerads.com") || d(h, "propellerpops.com") || d(h, "onclickads.net")) || 
	(d(h, "quantcount.com")) || 
	(d(h, "recreativ.ru")) || 
	(d(h, "revmob.com")) || 
	(d(h, "yieldmanager.com")) || 
	(d(h, "rubiconproject.com")) || 
	(d(h, "an.yandex.ru") || d(h, "lcads.ru") || d(h, "marketgid.com") || d(h, "livesmi.com") || d(h, "recreativ.ru") || d(h, "adtraff.ru") || d(h, "profitwizard.ru") || d(h, "bannerbank.ru")) || 
	(d(h, "24s.ru") || d(h, "addisp.com") || d(h, "addnow.ru") || d(h, "adizer.ru") || d(h, "adpix.ru") || d(h, "adpro.com.ua") || d(h, "adru.net") || d(h, "adsclick.ru") || d(h, "adsellers.net")) || 
	(d(h, "advertpay.ru") || d(h, "bannerbank.ru") || d(h, "begun.ru") || d(h, "goodadvert.com.ua") || d(h, "mg.dt00.net") || d(h, "neoban.su") || d(h, "rs.mail.ru") || d(h, "seopult.ru") || d(h, "wmip.ru")) || 
	(d(h, "rnmd.net") && s(u, "*m3u*")) || 
	(d(h, "aimatch.com")) || 
	(d(h, "eacdn.com")) || 
	(d(h, "smaato.com") || d(h, "smaato.net")) || 
	(d(h, "smartadserver.com")) || 
	(d(h, "snapmobile.asia")) || 
	(d(h, "startapp.com") || d(h, "startappexchange.com")) || 
	(d(h, "taboolasyndication.com") || d(h, "taboola.com")) || 
	(d(h, "tapjoyads.com") || d(h, "tapjoy.com")) || 
	(d(h, "tradedoubler.com") && !s(u, "*tradedoubler.com/click*") && !s(u, "*itunesredir*")) || 
	(d(h, "globaltraffico.com") || d(h, "traffichaus.com")) || 
	(d(h, "trafmag.com")) || 
	(d(h, "rarenok.biz")) || 
	(d(h, "transpera.com")) || 
	(d(h, "tribalfusion.com")) || 
	(d(h, "andomedia.com")) || 
	(d(h, "readserver.net") || d(h, "rtbpop.com") || d(h, "1phads.com") || d(h, "admngronline.com") || d(h, "dotandad.com") || d(h, "everestads.net")) || 
	(d(h, "fastclick.net")) || 
	(d(h, "vdopia.com")) || 
	(d(h, "adcel.vrvm.com")) || 
	(d(h, "intellitxt.com")) || 
	(d(h, "videoplaza.tv") || d(h, "videoplaza.com")) || 
	(d(h, "vkmonster.com")) || 
	(d(h, "vserv.mobi")) || 
	(d(h, "vungle.com")) || 
	(d(h, "wigetmedia.com")) || 
	(d(h, "yoc.mobi")) || 
	(d(h, "yumenetworks.com")) || 
	(d(h, "zedo.com")) || 
	(d(h, "a.zestadz.com") || d(h, "assets.zestadz.com")) || 
	(d(h, "zumobi.com")) || 
	(d(h, "google-analytics.com") || d(h, "parsely.com") || d(h, "sitemeter.com") || d(h, "statcounter.com")) || 
	(	(s(h, "ad.*") || s(h, "*.ad.*")) || 
		(s(h, "ads.*") || s(h, "*.ads.*")) || 
		(s(h, "adserv.*") || s(h, "*.adserv.*")) || 
		(s(h, "adserver.*") || s(h, "*.adserver.*")) || 
		(s(u, "*/ad/*") && !d(h, "mzstatic.com") && !d(h, "apple.com")) || 
		(s(u, "*/ads/*")) || 
		(s(u, "*/adserv/*")) || 
		(s(u, "*/adserver/*") && !d(h, "apple.com")) || 
		(s(u, "*/banner/*")) || 
		(s(u, "*/banners/*"))
	) || 
	(s(u, "*/mobiquo/mobiquo.php*") || s(u, "*/mobiquo/smartbanner/*.js*")) || 
	(d(h, "gravatar.com")) || 
	(d(h, "linkedin.com")) || 
	(d(h, "livefyre.com") || d(h, "fyre.co")) || 
	(s(u, "*apis.google.com/u/0/_/+1/fastbutton*")) || 
	(s(u, "*platform.twitter.com/widgets.js*")) || 
	(s(u, "*assets.pinterest.com/js/pinit.js*")) || 
	(s(u, "*.facebook.net/*/all.js*")) || 
	(s(u, "*facebook.com/plugins/like.php*")) || 
	(s(u, "*/fbcdn*akamaihd.net/hads*") || s(u, "*fbcdn.net/hads*")) || 
	(s(u, "*.twitter.com/widgets/tweet_button*"))
	  
	
	  
    ) {
	return BLACKHOLE; 
    }
	
    return DIRECT;
}

